﻿using IntoNails.Infrastructure.InteractionRequests;
using IntoNails.Models;
using IntoNails.Modules.CategoryManagement.InteractionRequests;
using IntoNails.Modules.CategoryManagement.ViewModels;

namespace IntoNails.Modules.CategoryManagement.Views
{
    /// <summary>
    /// Interaction logic for CreateNewServicePopupView.xaml
    /// </summary>
    public partial class CreateNewServicePopupView : CreateNewServiceDialogRequest, IGenericInteractionView<Service>
    {
        public CreateNewServicePopupView()
        {
            InitializeComponent();

            this.ViewModel = new CreateNewServicePopupViewModel();
            this.DataContext = this.ViewModel;
        }

        public CreateNewServicePopupViewModel ViewModel { get; private set; }

        public void SetEntity(Service entity)
        {
            this.ViewModel.SetEntity(entity);
        }

        public Service GetEntity()
        {
            return this.ViewModel.GetEntity();
        }
    }
}
